package com.zzyl.mapper;

import com.github.pagehelper.Page;
import com.zzyl.entity.NursingLevel;
import com.zzyl.vo.NursingLevelVo;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * @Description NursingLevelMapper
 * @Author LiShunSen
 * @Date 2024-08-28
 */
@Mapper
public interface NursingLevelMapper {
    /**
     * 查询所有护理等级
     *
     * @return
     */
    List<NursingLevelVo> getAll();
    /**
     * 新增
     *
     * @param nursingLevel
     * @return
     */
    void insertLevel(NursingLevel nursingLevel);
    /**
     * 分页查询
     *
     * @param name
     * @param status
     * @param pageNum
     * @param pageSize
     * @return
     */
    Page<NursingLevel> getByPage(@Param("name") String name, @Param("status") Integer status, @Param("pageNum") Integer pageNum, @Param("pageSize") Integer pageSize);

    NursingLevelVo getId(@Param("id") Long id);

    void updateLevel(NursingLevel nursingLevel);

    void deleteLevel(Long id);

    //启用/禁用
    void statusLevel(@Param("id") Long id, @Param("status") Integer status);
}
